package com.hopoke.store.controller;

import com.hopoke.api.UserClient;
import lombok.RequiredArgsConstructor;
import org.springframework.web.bind.annotation.CrossOrigin;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@CrossOrigin
@RequestMapping("/store")
@RequiredArgsConstructor
public class StoreController {

    private final UserClient userClient;

    @GetMapping("/getStoreList")
    public String getStoreList() {
        String user = userClient.getUserById(1);
        System.out.println(user);
        return "返回内容：" + user;
    }
}
